﻿using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace _51foreach循环
{
    class Program
    {
        static void Main(string[] args)
        {
            int[] nums = { 1, 2, 3, 4, 5, 6, 67, 7, 8 };
            for (int i = 0; i < nums.Length; i++)
            {
                Console.WriteLine(nums[i]);
            }
            Console.WriteLine("==============");
            foreach (var item in nums)
            {
                Console.WriteLine(item);
            }
            Console.ReadKey();

            //Stopwatch sw = new Stopwatch();
            //sw.Start();
            //int[] num = new int[1000];
            //foreach (var item in num)
            //{
                
            //}
            //for (int i = 0; i < 1000; i++)
            //{

            //}
            //sw.Stop();
            //Console.WriteLine(sw.Elapsed);            
            Console.ReadKey();
        }
    }
}
